#include "StdAfx.h"
#include "CDirMonitor.h"
#include <boost/thread/thread.hpp>


CDirMonitor::CDirMonitor(void)
{
}

CDirMonitor::~CDirMonitor(void)
{
}

void CDirMonitor::AddDir(const std::string &Dir, bool RecursiveScan)
{
  m_data.m_strDir = Dir;
}

void CDirMonitor::AddMask(const std::string &Mask)
{
}

void CDirMonitor::RunScanThread(CScanThread &threadObject, IDirChangedFeedback &feedback)
{
  boost::thread thrd1(threadObject);

  m_data.notify_handle[1] = CreateStopEvent();

  thrd1.join();



}

HANDLE CDirMonitor::CreateStopEvent()
{
  return CreateEvent(NULL,FALSE, FALSE, NULL);
/*HANDLE WINAPI CreateEvent(
  __in_opt  LPSECURITY_ATTRIBUTES lpEventAttributes,
  __in      BOOL bManualReset,
  __in      BOOL bInitialState,
  __in_opt  LPCTSTR lpName
);*/
}